unit fAdvertismentSel;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, dxExEdtr, dxTL, dxDBCtrl, dxDBGrid, dxCntner, uCommonclass, DB,
  DBClient;

type
  TfrmAdvertismentSel = class(TForm)
    dxdbgrd1: TdxDBGrid;
    dxdbgrdclmnAdvertismentCode: TdxDBGridColumn;
    dxdbgrdclmnSize: TdxDBGridColumn;
    dxdbgrdclmnComments: TdxDBGridColumn;
    cds1: TClientDataSet;
    ds1: TDataSource;
    procedure FormCreate(Sender: TObject);
    procedure FormShow(Sender: TObject);
    procedure dxdbgrd1DblClick(Sender: TObject);
  private
    { Private declarations }
    gDBSuperMan: TDBSuperMan;    
  public
    { Public declarations }
  end;

var
  frmAdvertismentSel: TfrmAdvertismentSel;

implementation

{$R *.dfm}

procedure TfrmAdvertismentSel.FormCreate(Sender: TObject);
begin
  gDBSuperMan := TDBInquireSuperMan.Create;
end;

procedure TfrmAdvertismentSel.FormShow(Sender: TObject);
begin
  gDBSuperMan.Table := 'BI_Advertisment';
  gDBSuperMan.DBGrid := dxdbgrd1;
  gDBSuperMan.FieldsPanel := nil;
  gDBSuperMan.PrepareData;
  gDBSuperMan.ExecuteOperate;
end;

procedure TfrmAdvertismentSel.dxdbgrd1DblClick(Sender: TObject);
begin
  ModalResult := mrOk;
end;

end.
